package com.qc.ayouth.shop.admin.service.shop;

import com.alibaba.fastjson.JSONObject;
import com.qc.ayouth.shop.admin.beans.dto.CategoryDto;
import com.qc.ayouth.shop.admin.beans.dto.CategorySimpleDto;
import com.qc.ayouth.shop.core.beans.bo.ServiceResultBO;
import com.qc.ayouth.shop.core.beans.bo.ValidResultBO;
import com.qc.ayouth.shop.dbs.entity.TSystemAdmin;

import java.util.List;

/**
 * Created by Haojg on 2020/7/9
 */
public interface AdminCategoryService {
    /**
     * @description: 获取所有的商品分类列表
     * @author: haojg
     * @date: 2020/7/10 16:47
     * @param
     * @return: com.qc.ayouth.shop.core.beans.bo.ServiceResultBO
     */
    ServiceResultBO getGoodsCategoryList();

    /**
     * @description: 获取父级类目列表：简单模式
     * @author: haojg
     * @date: 2020/7/11 10:52
     * @param
     * @return: java.util.List<com.qc.ayouth.shop.admin.beans.dto.CategorySimpleDto>
     */
    List<CategorySimpleDto> getMainCategoryList();

    /**
     * @description: 获取一级分类
     * @author: haojg
     * @date: 2020/7/13 14:31
     * @return: java.util.List<com.qc.ayouth.shop.admin.beans.dto.CategoryDto>
     */
    List<CategoryDto> getCategoryList();

    /**
     * @description: 获取分类的子分类
     * @author: haojg
     * @date: 2020/7/13 14:31
     * @param catId
     * @return: java.util.List<com.qc.ayouth.shop.admin.beans.dto.CategoryDto>
     */
    List<CategoryDto> getCategoryChildrenList(Long catId);

    /**
     * @description: 创建分类时，进行参数验证
     * @author: haojg
     * @date: 2020/7/13 9:45
     * @param params
     * @return: com.qc.ayouth.shop.core.beans.bo.ValidResultBO
     */
    ValidResultBO validCreateCategory(JSONObject params);


    Boolean saveCategory(JSONObject params);
    Boolean updateCategory(JSONObject params);
    Boolean deleteCategory(Long id);
}
